package com.itheima;

import com.itheima.dao.BookDao;
import com.itheima.entitiy.Book;
import com.itheima.service.BookService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @Author: lh
 * @Date: 2023/4/27 11:07
 * @Package:com.itheima
 */

public class App {
    public static void main(String[] args) {
       ApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");

        BookDao bookDao = context.getBean("bookDao", BookDao.class);

        BookService lh = context.getBean(BookService.class);
        System.out.println(lh);

        System.out.println(bookDao);
    }
}
